// This file was created by Filewrap 1.1
// Little endian mode
// DO NOT EDIT

#include "../PVRTMemoryFileSystem.h"

// using 32 bit to guarantee alignment.
#ifndef A32BIT
 #define A32BIT static const unsigned int
#endif

// ******** Start: SlowVertShader.vsh ********

// File data
static const char _SlowVertShader_vsh[] = 
	"/******************************************************************************\r\n"
	"* Vertex Shader (Slow method)\r\n"
	"*******************************************************************************\r\n"
	" This technique uses the most significant normal to the grained surface (i.e.\r\n"
	" normal in same plane as light vector and eye direction vector) to calculate\r\n"
	" intensities for the diffuse and specular lighting, which create an anisotropic\r\n"
	" effect. The diffuse lighting factor is defined as the dot product of the light\r\n"
	" direction and the normal (L.N). The specular lighting factor is defined as the\r\n"
	" square of the dot product of the view vector (eye direction) and the\r\n"
	" reflection vector ((V.R) * (V.R)). \r\n"
	" For convenience these can be expressed in  terms of the the light direction \r\n"
	" (L), view direction (V) and the tangent to the surface (T). Where the \r\n"
	" direction of the tangent points along the grain.\r\n"
	"******************************************************************************/\r\n"
	"attribute highp vec3  inVertex; \r\n"
	"attribute highp vec3  inNormal;\r\n"
	"\r\n"
	"uniform highp mat4  MVPMatrix;\r\n"
	"uniform highp vec3  msLightDir;\r\n"
	"uniform highp vec3  msEyeDir;\r\n"
	"uniform highp vec4  Material; \r\n"
	"uniform highp vec3  GrainDir;\r\n"
	"\r\n"
	"varying lowp vec3  DiffuseIntensity; \r\n"
	"varying lowp vec3  SpecularIntensity; \r\n"
	"\r\n"
	"void main() \r\n"
	"{\r\n"
	"\t// Transform position\r\n"
	"\tgl_Position = MVPMatrix * vec4(inVertex, 1.0);\r\n"
	"\t\r\n"
	"\t// Calculate the cross product of normal and grain direction.\r\n"
	"\t// Cross product this with the normal. The result is a vector which is \r\n"
	"\t// perpendicular to the surface and follows the direction of the grain.\r\n"
	"\thighp vec3 normalXgrain = cross(inNormal, GrainDir);\r\n"
	"\thighp vec3 tangent = normalize(cross(normalXgrain, inNormal));\r\n"
	"\t\r\n"
	"\thighp float LdotT = dot(tangent, msLightDir);\r\n"
	"\thighp float VdotT = dot(tangent, msEyeDir);\r\n"
	"\t\r\n"
	"\thighp float NdotL = sqrt(1.0 - LdotT * LdotT);\r\n"
	"\thighp float VdotR = NdotL * sqrt(1.0 - VdotT * VdotT) - VdotT * LdotT;\t\r\n"
	"\r\n"
	"\t// Calculate the diffuse intensity, applying scale and bias.\r\n"
	"\tDiffuseIntensity = vec3(NdotL * Material.x + Material.y);\r\n"
	"\t\r\n"
	"\t// Calculate the specular intensity, applying scale and bias.\r\n"
	"\tSpecularIntensity = vec3(VdotR * VdotR * Material.z + Material.w); \r\n"
	"}\r\n";

// Register SlowVertShader.vsh in memory file system at application startup time
static CPVRTMemoryFileSystem RegisterFile_SlowVertShader_vsh("SlowVertShader.vsh", _SlowVertShader_vsh, 2210);

// ******** End: SlowVertShader.vsh ********

// This file was created by Filewrap 1.1
// Little endian mode
// DO NOT EDIT

#include "../PVRTMemoryFileSystem.h"

// using 32 bit to guarantee alignment.
#ifndef A32BIT
 #define A32BIT static const unsigned int
#endif

// ******** Start: SlowVertShader.vsc ********

// File data
A32BIT _SlowVertShader_vsc[] = {
0x10fab438,0x9dba60a0,0x30050100,0x2501,0xd363e337,0x2000000,0x20000000,0x6d050000,0x0,0x4000000,0x0,0x19000000,0x303,0x0,0x1010000,0x0,0x0,0x9c030000,0x55535020,0x20,0x390,0x1,0x1,0x0,0x204,0x80,0x2,0x7d,0x0,0x8,0x0,0xffffffff,0x0,0x122000a,0xffff,0x40007,0x0,0x0,0x1e,0x0,0x0,0x0,0x0,0xfffc,0x0,0x0,0x0,0xffff0003,0xffffffff,0x1e0000,0x800007,0x10001,0x0,0x20001,0x1,0x30001,0x2,0x40001,0x3,0x50001,0x4,0x60001,0x5,0x70001,
0x6,0x80001,0x7,0x90001,0x8,0xa0001,0x9,0xb0001,0xa,0xc0001,0xb,0xd0001,0xc,0xe0001,0xd,0xf0001,0xe,0x100001,0xf,0x110001,0x10,0x120001,0x11,0x130001,0x12,0x140001,0x13,0x150001,0x14,0x160001,0x15,0x180001,0x16,0x190001,0x17,0x1a0001,0x18,0x1c0001,0x19,0x1d0001,0x1a,0x1e0001,0x1b,0x1f0001,0x1c,0x5,0x1d3f80,0x770000,0xffff0000,0xffffffff,0xffff,0x0,0x40000,0x30000,0x2,0x20006,0x80018001,0x80018001,0x0,0x0,0x0,0x0,0x0,0xd06185b0,
0x811006,0xd0010630,0x811005,0xd0214530,0x811005,0xe0414603,0x80100c,0xd0618500,0x80100c,0xd0210581,0x80100c,0x2,0x20002,0x80018001,0x80004009,0x0,0x0,0x4,0x1010900,0xfa100002,0x90004230,0xa12001,0x2,0x20002,0x40128001,0x80014012,0x0,0x0,0x4,0x1121201,0xfa100006,0x90004200,0xa02008,0x2,0x2000d,0x80018001,0x80018000,0x0,0x0,0x4,0x0,0x0,0x10001,0x1,0x10001,0x10001,0x101,0x81fa10,0x14020060,0x81030080,0x10022060,0x1800080,0x120280a0,0x82b00880,0x10029080,0x68e0081,0x606f060,0x489238ab,0x606f060,0x8a963882,0x606f060,0x1a193882,0x1001701f,0x79000a2,
0x606f000,0x499438ab,0x606f000,0x8b983882,0x606f000,0x1a1b3882,0x1001705f,0x200a2,0x110000,0x80010002,0x80018001,0x8001,0x0,0x40000,0x10000,0x10001,0x10001,0x10001,0x10001,0x1,0x0,0x0,0x1010101,0xfa100000,0x14001,0x38ab0606,0xf01f0ea0,0x38980602,0xf0000f21,0x38820606,0xf0010fa2,0x38820606,0xd01f40b4,0x831082,0x80000000,0x8801202,0x80400000,0x8801002,0x301f3e27,0x388dc622,0xc0200000,0x8821202,0x80600080,0x8801002,0xb060c101,0x81100c,0xf080d1a4,0x801005,0x60a00200,0x28a11001,0x10a0c1b0,0x811002,0xf0e152a6,0x801005,0x61000380,0x28a11001,0x6,0x803f2000,0x0,0x0,0x0,0x0,0x0,0x0,
0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0xa000000,0x65566e69,0x78657472,0x4000000,0x304,0x1000001,0x40000,0x67000007,0x6f505f6c,0x69746973,0x6e6f,0x3050501,0x10000,0x100,0xf0004,0x50564d00,0x7274614d,0x7869,0x3031600,0x10000,0x4000100,0xffff10,0x4e6e6900,0x616d726f,0x6c,0x30404,0x100,0x4040001,0x700,0x69617247,0x7269446e,0x4000000,0x303,0x1000001,0x30100,0x6d000007,0x67694c73,0x69447468,0x72,
0x30304,0x100,0x3140001,0x700,0x7945736d,0x72694465,0x4000000,0x303,0x1000001,0x31800,0x4d000007,0x72657461,0x6c6169,0x3050000,0x1000003,0x10000,0xf00041c,0x69440000,0x73756666,0x746e4965,0x69736e65,0x7974,0x1050400,0x10000,0x100,0x70003,0x65705300,0x616c7563,0x746e4972,0x69736e65,0x7974,0x1050400,0x10000,0x4000100,0x70003,0x0,
};

// Register SlowVertShader.vsc in memory file system at application startup time
static CPVRTMemoryFileSystem RegisterFile_SlowVertShader_vsc("SlowVertShader.vsc", _SlowVertShader_vsc, 1421);

// ******** End: SlowVertShader.vsc ********

